package com.dhcc.bpm.modules.scf.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.IService;
import com.dhcc.bpm.modules.scf.dto.ScfRecyclingWeighInfoDTO;
import com.dhcc.bpm.modules.scf.entity.ScfRecyclingWeighInfo;
import com.dhcc.bpm.modules.scf.vo.ScfRecyclingWeighInfoVO.ScfGetRecyclingWeighDetailsVO;
import com.dhcc.bpm.modules.scf.vo.ScfRecyclingWeighInfoVO.ScfGetRecyclingWeighListVO;
import org.springframework.web.multipart.MultipartFile;

import java.io.IOException;
import java.util.List;


/**
 * 利废企业入库单服务层接口
 */
public interface IScfRecyclingWeighInfoService extends IService<ScfRecyclingWeighInfo> {
    /**
     * 自定义查询列表
     *
     * @param page
     * @param scfRecyclingWeighInfo
     * @return
     */
    IPage<ScfGetRecyclingWeighListVO> selectScfRecyclingWeighInfoPage(IPage<ScfGetRecyclingWeighListVO> page, ScfRecyclingWeighInfoDTO scfRecyclingWeighInfo);

    /**
     * 查看磅单详情
     *
     * @param scfRecyclingWeighInfo
     * @return
     */
    ScfGetRecyclingWeighDetailsVO getDetail(ScfRecyclingWeighInfoDTO scfRecyclingWeighInfo);

    /**
     * 新增磅单信息
     *
     * @param scfRecyclingWeighInfo
     * @return
     */
    Boolean saveRecyclingWeighInfo(ScfRecyclingWeighInfoDTO scfRecyclingWeighInfo) throws Exception;

    /**
     * 新增磅单信息
     *
     * @param scfRecyclingWeighInfos
     * @return
     */
    int bachSaveRecyclingWeighInfo(List<ScfRecyclingWeighInfo> scfRecyclingWeighInfos, String operatorId);

    /**
     * 更新磅单信息
     *
     * @param scfRecyclingWeighInfo
     * @return
     */
    Boolean updateRecyclingWeighInfo(ScfRecyclingWeighInfoDTO scfRecyclingWeighInfo) throws Exception;

    /**
     * 利废过磅信息-批量导入
     * 当前用户ID
     *
     * @param file
     * @return
     */
    List<ScfRecyclingWeighInfo> batchSaveRecyclingWeighInfo(String operatorId, MultipartFile file) throws IOException;

    Boolean deleteByIds(String[] split);
}
